package config;

import org.springframework.amqp.core.Queue;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * 生产者消费者模式的配置,包括一个队列和两个对应的消费者
 * 
 * @author super
 *
 */
@Configuration
public class ProducerConsumerConfig {
	
	/** 生产者消费者模式-队列 */
	public static final String QUERY_NAME = "myqueue";
	

	@Bean
	public Queue myQueue() {
		Queue queue = new Queue(QUERY_NAME);
		return queue;
	}

}
